package de.bk.timecalc.core;

import de.bk.timecalc.i18n.I18nKeys;
import de.bk.timecalc.i18n.StringFactory;

public enum Item
{
  // Weapon/Duel,FFA,CA: 5
  // W/TDM: 12
  // Armor: 25
  // Health: 35 (MH sometimes 2min)
  // Quad: 2min

  QUAD("Quad", 120)
  {
    @Override
    public String getDisplayText()
    {
      return "2"
          + StringFactory.getInstance().getString(I18nKeys.DIFFERENCE_MINUTES);
    }
  },

  MEGA_HEALTH("Mega Health", "MH", 35),

  RED_ARMOR("Red Armor", "RA", 25),

  WEAPON_IN_TDM("Weapon/TDM", 12),

  WEAPON("Weapon", 5);

  private String name;
  private String shortName;
  private int seconds;

  private Item(String name, int seconds)
  {
    this(name, name, seconds);
  }

  private Item(String name, String shortName, int seconds)
  {
    this.name = name;
    this.shortName = shortName;
    this.seconds = seconds;
  }

  public final String getName()
  {
    return this.name;
  }

  public final String getShortName()
  {
    return this.shortName;
  }

  public final int getSeconds()
  {
    return this.seconds;
  }

  public String getDisplayText()
  {
    return this.seconds
        + StringFactory.getInstance().getString(I18nKeys.DIFFERENCE_SECONDS);
  }
}